var myChart = echarts.init(document.getElementById("idx1"));
var option = {
    series:{
        type:'map',
        map:'china',
    },
};
myChart.setOption(option);
//--------------------------
var myChart2 = echarts.init(document.getElementById("idx2"));
var option2 = {
    series:{
        type:'map',
        map:'world',
    },
};
myChart2.setOption(option2);
 
var myChart3 = echarts.init(document.getElementById("idx3"));
var option3 = {
    series:{
        type:'map',
        map:'china',
        selectedMode: 'multiple',
        roam: true,
        left: 0,
        right: 0,
        bottom: 0,
        top: 0,
        select:{
            itemStyle:{
                areaColor:'red',
            }
        }      
    },
};
myChart3.setOption(option3);
//----------------------------
var myChart4 = echarts.init(document.getElementById("idx4"))
var option4 = {
    visualMap: {
        max:15,
        min:1,
        range:[2,10],
        inRand:{
            color:['green','yellow']
        },
        calculable:'true',
        top:'bottom',
        left:'center',
        orient:'horizontal',
    },
    series:{
        type:'map',
        map: 'china',
        selectedMode: 'multiple',
        roam: true,
        data: [{
            name: '浙江',
            value: 10,
            label: {
                show: true,
                color:'black',
            },
            itemStyle: {
                areaColor: 'yellow',
            },
        },{
            name: '福建',
            value: 5,
            label: {
                show: true,
            },
        },{
            name: '广东',
            value: 1,
            label: {
                show: true,
            },
            itemStyle: {
                areaColor: 'red',
            },
        }],
        //boundingCoords: [[-180,90],[180,-90]],
    },
};
myChart4.setOption(option4)
//--------------------------------
var myChart5 = echarts.init(document.getElementById("idx5"))
var option5 = {
    geo: {
        map: 'china',
        roam: true,
        itemStyle: {
            areaColor: 'gray',
        },
    },
};
myChart5.setOption(option5)
//--------------------------------
var myChart6 = echarts.init(document.getElementById("idx6"))
var option6 = {
    geo: {
        map: 'china',
        roam: true,
    },
    series: [{
        type:'scatter',
        coordinateSystem: 'geo',
        data:[{
            name: '北京',
            value: [116.20,39.96,34],
        },{
            name: '上海',
            value: [121.47,31.23,25],
        },{
            name: '广东',
            value: [113.5,22.5,20],
        },{
            name: '陕西',
            value: [108.5,33.5,15],
        }]
    }],
};
myChart6.setOption(option6)